package com.sherlock.premssion.controller;
import com.sherlock.premssion.entity.TestEntity;
import com.sherlock.premssion.service.TestService;
import com.sherlock.premssion.utils.RUtil;
import com.sherlock.premssion.vo.R;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.apache.shiro.realm.AuthenticatingRealm;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * description：
 * author     ：rwj
 * date       ：2021/1/21 9:22
 */
@Api(tags ="测试接口")
@RestController
@RequestMapping("/sys")
@Slf4j
public class testController {

    @Autowired
    private TestService testSerice;

    @ApiOperation(value = "查询角色列表")
    @GetMapping("/selectTestList")
    public R selectRoleList(@RequestParam(value = "id", defaultValue = "0") int id){
        TestEntity entity = testSerice.selectOne(id);
        return RUtil.success(entity);

    }
}
